Skip to content

feat: allow injecting into all extensions#592

Open
waruhachi wants to merge 4 commits intoclaration:mainfrom
waruhachi:main
Open

feat: allow injecting into all extensions#592
waruhachi wants to merge 4 commits intoclaration:mainfrom
waruhachi:main

Conversation

@waruhachi
Copy link

@waruhachi waruhachi commented Feb 25, 2026

This pull request adds support for injecting tweaks into all app extensions, including plugins and extensions, in addition to the main app bundle as mentioned in #584.

A toggle button is added in the Tweak section of the Modify settings. This setting is not persistent and is disabled by default.

Image

Copilot AI review requested due to automatic review settings February 25, 2026 17:31

This comment was marked as spam.

Comment on lines +293 to +297
guard let extensionBundle = Bundle(url: extensionURL),
let extensionExecutable = extensionBundle.executableURL else {
Logger.misc.warning("Skipping \(extensionURL.lastPathComponent): couldn't read bundle")
return
}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
guard let extensionBundle = Bundle(url: extensionURL),
let extensionExecutable = extensionBundle.executableURL else {
Logger.misc.warning("Skipping \(extensionURL.lastPathComponent): couldn't read bundle")
return
}
guard
let extensionBundle = Bundle(url: extensionURL),
let extensionExecutable = extensionBundle.executableURL
else {
Logger.misc.warning("Skipping \(extensionURL.lastPathComponent): couldn't read bundle")
return
}

Comment on lines +100 to +102
if !_injectedDylibNames.isEmpty {
_injectIntoAllExtensions(dylibNames: _injectedDylibNames)
}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if !_injectedDylibNames.isEmpty {
_injectIntoAllExtensions(dylibNames: _injectedDylibNames)
}
if _options.injectIntoExtensions && !_injectedDylibNames.isEmpty {
_injectIntoAllExtensions(dylibNames: _injectedDylibNames)
}


// Injects all dylibs into all discovered extensions
private func _injectIntoAllExtensions(dylibNames: [String]) {
guard _options.injectIntoExtensions else { return }
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
guard _options.injectIntoExtensions else { return }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants